Field of the Invention
The present invention relates to processing for generating a wide viewing angle (panoramic) image by combining a plurality of partially overlapping images.
Description of the Related Art
In the case of generating 1 wide viewing angle (panoramic) image by combining a plurality of images captured in a partially-overlapping manner so as to include the same subject, it is necessary to smoothly connect the images at the boundary portion. Thus, in the overlap region of at least 2 adjacent images, the images are combined by blending (weighted-adding) pixel values of corresponding pixels. Japanese Patent Laid-Open No. 2011-193062 discloses a method for combining images in the following manner. First, in the overlap region of adjacent images, the amount of movement between 2 images is calculated for each block. Then, pixel values of pixels in each block of the 2 images are weighted-added using a weighted ratio set according to the movement amount. As for pixels with a large amount of movement between the images, a positional difference is easily generated. Thus, pixel values of the pixels in the 2 images are weighted-added while applying a larger weight on the pixel values of one image. In contrast, as for pixels with a small amount of movement between the images, pixel values of the pixels in the 2 images are weighted-added while applying a weight of 0.5 on the pixel values of both images.
Nevertheless, in the method disclosed in Japanese Patent Laid-Open No. 2011-193062, if a positional difference is generated between 2 images in the overlap region, the weighted-addition of pixel values of corresponding pixels generates a multiple overlapping image and deteriorates sharpness in an edge portion. On the other hand, in a flat portion in the overlap region, the switching of a weight for performing weighted-addition generates an artifact in some cases. For example, a color discontinuously changes on a boundary line.